Page({
  editHouse() {
    wx.navigateTo({
      url: `/house_pkg/pages/form/index?id=${this.data.houseDetail.id}`,
    })
  },
  data: {
    houseDetail: {},
  },
  onLoad({ id }) {
    this.getDetail(id)
  },
  // 获取房屋详情
  async getDetail(id) {
    const { data: houseDetail } = await wx.http.get(`/room/${id}`)
    this.setData({ houseDetail })
  },
})
